import * as React from 'react';
import * as ReactDom from 'react-dom';
const { useState } = React;
function App() {
    const [count, setCount] = useState(0)
    return <div>
        <div>count: {count}</div>
        <button onClick={() => setCount(val => val+1)}>add</button>
    </div>
}

ReactDom.render(<App />, document.getElementById('root'));